import {createStore} from 'vuex'
import user from './modules/user'
import config from './modules/config'
import setting from './modules/setting'
import routes from './modules/routes'

const modules = {}
modules["user"] = user
modules["config"] = config
modules['setting'] = setting
modules['routes'] = routes

Object.keys(modules).forEach((key) => {
    modules[key]['namespaced'] = true
})

export default createStore({
    modules
})